
import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart';
import 'package:flutter_app/blocs/network_connectivity_bloc/network_connectivity_bloc.dart';

class AlertNetWorkChangeMessage extends StatelessWidget{
  final NetWorkConnectivityState ncState;
  AlertNetWorkChangeMessage({@required this.ncState});
  @override
  Widget build(BuildContext context) {
    // TODO: implement build
    return Visibility(
      visible: ncState.isShow,
      child: Center(
        child: Container(
          margin: EdgeInsets.all(10),
          decoration: BoxDecoration(
            color: Theme.of(context).primaryColor,
            boxShadow: [
              BoxShadow(
                color: Theme.of(context).primaryColor,
                //offset: Offset(2.0,2.0),
                blurRadius: 1.0,
              )
            ],
          ),
          child: Text(ConnectivityTypeMessage[ncState.connectivityType]),
        ),
      ),
    );
  }
}